<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<style type="text/css">
body {
	*background-image:url(about:blank);
	*background-attachment:fixed;/*必要，防抖动*/
	padding:0px;
	margin:0px;
}
.head{top:0px;}
.head, .foot {
	position:fixed !important;/*ie7 ff*/
	position:absolute;
	z-index:21;
	height:30px;
	line-height:30px;
	width:100%;
}
.headin{width:500px;background:#999;margin: 0px auto;height:30px;cursor:pointer;}
.footin{width:500px;background:#999;margin: 0px auto;height:30px;}
.foot {
	bottom:0 !important;/*ie7 ff*/
}
</style>
<!--[if IE 6]>
<style type="text/css">
/*ie6 fix顶端元素*/
    .head{
    *top:expression(eval(document.documentElement.scrollTop));
}
/*ie6 fix底端元素*/
.foot{
 *top: expression(eval((document.compatMode&&document.compatMode=="CSS1Compat")?documentElement.scrollTop+documentElement.clientHeight-this.clientHeight-1:document.body.scrollTop+document.body.clientHeight-this.clientHeight-1));
}
</style>
<![endif]-->
<script language="JavaScript">

function toDesktop()
{
	var navigatorName = "Microsoft Internet Explorer";
	if( navigator.appName != navigatorName ) { 
		alert('当前浏览器不支持该功能');
		return false;
	}
	var sUrl = 'http://www.baidu.com/';
	//var sUrl = 'c:/';
	var sName = 'test';
	try
	{
		var WshShell = new ActiveXObject("WScript.Shell");
		var oUrlLink = WshShell.CreateShortcut(WshShell.SpecialFolders("Desktop") + "\\"	+ sName + ".url");
		oUrlLink.TargetPath = sUrl;
		oUrlLink.Save();
	}
	catch(e)
	{
		alert("当前IE安全级别不允许操作！请设置后在操作.");
	}
}
</script>
</head>

<body>
<div class="head"> <div class="headin" onclick="toDesktop()">header</div> </div>
<div class="main">
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
  <p>main </p>
</div>
<div class="foot"> <div class="footin">foot</div> </div>
</body>
</html>